Bilevel problem with 3 VI's at lower level emp JAMS GAMS short = 1 (u,v) solves VI( [v+y+z-1; u-log(v)], {(u,v) | u >= 0, v >= 0 } ) y solves VI( y+z+3, { y | y free } ) Note that the two VI's (due to the definitional sets) correspond respectively to a complementarity problem: 0 <= u \perp v + y + z - 1 >= 0 0 <= v \perp u - log(v) >= 0 and a linear equation: y + z + 3 = 0 The starting value for v is needed to protect the evaluation of log(v). Contributor: Michael Ferris and Jan-H. Jagla, December 2009 $offtext positive variable u; variables v, y, z; equations f1,f2,f3,h; f1.. v + y + z =n= 1; f2.. u =e= log(v); f3.. y + z =n= -3; h.. exp(z) + y =e= 2; v.lo = 0; v.l = 1; z.lo = 1; model mpec /all/; $onecho > %emp.info% bilevel vi f1 u vi f2 v vi f3 y $offecho solve mpec using emp min z; ]]>